import { defineConfig } from 'vite'
import vue from '@vitejs/plugin-vue'
import {resolve} from 'path';

// https://vitejs.dev/config/
export default defineConfig({
  plugins: [vue()],
  server: {
		// 运行端口
		port: 8080
	},
	build: {
		// 多页面打包配置
		rollupOptions: {
			input: {
				// 配置所有页面路径，使得所有页面都会被打包
				main: resolve(__dirname, 'index.html'),
				login: resolve(__dirname, 'login/index.html'),
				detail: resolve(__dirname, 'detail/index.html'),
				addF: resolve(__dirname, 'addF/index.html'),
				group: resolve(__dirname, 'group/index.html'),
			}
		}
  }
})
